import { ref } from 'vue';

export const useLoading = () => {
  const loading = ref(false);
  const btn = () => {
    loading.value = true;
    setTimeout(() => {
      loading.value = false;
    }, 1000);
  };
  return { loading, btn };
};